/**
 * Copyright (C), 2015-2019, XXX有限公司
 * FileName: RedisKeyManager
 * Author:   zhouheng
 * Date:     2019/4/14 20:34
 * Description:
 * History:
 * <author>          <time>          <version>          <desc>
 * 作者姓名           修改时间           版本号              描述
 */
package com.activity.services.processor.constants;

import com.activity.dal.entitys.ActDrawAward;
import com.activity.draw.bean.ActivityTurntableDrawReq;

/**
 * 〈一句话功能简述〉<br> 
 * 〈〉
 *
 * @author zhouheng
 * @create 2019/4/14
 * @since 1.0.0
 */
public class RedisKeyManager {

    /**
     * @description: redis 奖项对应的奖品key 拼接
     * @date: 2019/4/15 22:49
     * @author:zhouheng
     */
    public static String getAwardRedisKey(ActDrawAward actDrawAward){
        return DrawContants.DRAW_AWARD+actDrawAward.getAwardType()+":"+actDrawAward.getId();
    }

    /**
     * @description: 获取当前证在抽奖用户对应的redis key
     * @date: 2019/4/15 22:53
     * @author:zhouheng
     */
    public static String getDrawingRedisKey(ActivityTurntableDrawReq activityTurntableDrawReq){
        return  DrawContants.DRAWING_PREFIX + activityTurntableDrawReq.getUid();
    }
}